.radioContainer {
  display: grid;
  gap: 5px;
  justify-content: space-around;
  align-content: center;
  border: none;
  /* Due to grid-blowout we need to set a max-width here or the inputs will
  subtly creep out of the box and cause horizontal scrollbars to appear */
  max-width: 100%;
  min-width: 0;
  grid-template-columns: repeat(auto-fill, minmax(40px, auto));
  padding: 0;
}

.option {
  height: var(--height-sm);
  width: 100%;
}

/* Hide the little button icon because we take over the showing with outlines
and background colors */
.option > .radioInput {
  display: none;
}

.radioLabel {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 4px 12px;
  border: 1px solid var(--light-grey);
  border-radius: var(--corner-radius);
  background-color: var(--rstudio-white);
  max-height: 105px;
  height: 100%;
  padding: 2px;
  color: var(--rstudio-blue);
  position: relative;
}

.icon {
  height: 100%;
  display: block;
}
.radioLabel svg {
  height: 1.65rem;
  padding: 1px;
  font-size: 1.6rem;
}

.radioInput:checked + .radioLabel {
  outline: 3px solid var(--rstudio-blue);
  outline-offset: -2px;
  font-weight: bold;
}

.radioInput:hover:not(:checked) + .radioLabel {
  outline: 2px solid var(--rstudio-blue);
}

/* When the user hovers over an icon for a second, fade out the icon and fade in
the label */
.radioInput:hover + .radioLabel::after,
.radioInput:hover + .radioLabel .icon {
  transition-property: opacity;
  transition-duration: 1.5s;
  transition-delay: 0.15s;
}

.radioInput + .radioLabel::after {
  content: attr(data-name);
  opacity: 0;
  position: absolute;
  pointer-events: none;
}

.radioInput:hover + .radioLabel::after {
  transition-timing-function: ease-in;
  opacity: 1;
}

.radioInput:hover + .radioLabel .icon {
  transition-timing-function: ease-out;
  opacity: 0;
}

.text_only_label {
  /* padding: var(--size-md); */
}
